import Vue from 'vue'
import Vuex from 'vuex'
Vue.use(Vuex)
const store = new Vuex.Store({
    state: {
		globalNum:11,
	},
	getters:{
		changeStateNum(state){
			return state.globalNum+11
		}
	},
    mutations: {
		changeNum(state,payload){
			state.globalNum=payload
		}
	},
    actions: {
		changeNum1(context,payload){
				context.commit("changeNum",payload)
		}
	},
	modules:{}
})
export default store